#include <grp.h>

#include <pwd.h>

#include <sys/types.h>

#include <unistd.h>

#include <stdlib.h>

#include <stdio.h>

int main (void)

{

  uid_t me;

  struct passwd *my_passwd;

  me = getuid ();

  my_passwd = getpwuid (me);

  if (!my_passwd)

  {

      printf ("Couldn't find out about user %d.\n", (int) me);

      exit (EXIT_FAILURE);

  }

printf("name\tpasswd\tuid\tgid\tdictionary\tshell\t\n");

  printf ("%s.\t%s.\t%d.\t%d.\t%s.\t%s.\t\n", my_passwd->pw_name,my_passwd->pw_passwd, (int) (my_passwd->pw_uid), (int) (my_passwd->pw_gid), my_passwd->pw_dir, my_passwd->pw_shell);

  return EXIT_SUCCESS;

}